import Shop from './index.vue';
import List from './list.vue';
import Add from './add.vue';
import updateGoods from './updateGoods.vue';
import updateClassify from './updateClassify.vue';
import classify from './calssify.vue';
import AddClassify from './addClassify';
import { addApi } from '@/utils/http';
export default {
	name: "shop",
	path: "shop",
	component: Shop,
	meta: {
		title: "商城",
		menu: "融酒商城"
	},
	children: [{
			name: "list",
			path: "",
			component: List,
			alias: "list",
			meta: {
				title: "商品列表"
			}
		},
		{
			name: "add",
			path: "add",
			component: Add,
			meta: {
				title: "商品新增"
			}
		},
		{
			name: "updateGoods",
			path: "updateGoods/:id",
			component: updateGoods,
			meta: {
				title: "商品修改"
			}
		},
		{
			name: "updateClassify",
			path: "updateClassify/:id",
			component: updateClassify,
			meta: {
				title: "分类修改"
			}
		},
		{
			name: "calssify",
			path: "classify",
			component: classify,
			meta: {
				title: "分类管理"
			}
		},
		{
			name: "addclassify",
			path: "addclassify",
			component: AddClassify,
			meta: {
				title: "新增分类"
			}
		}
	]
}

export const Api = {
	categoryAdd: "category/add", //分类添加
	categoryList: "category/query", //分类列表
	categoryDetails: "category/queryDetails", //分类详情
	categorySave: "category/save",//分类保存

	productList: "product/query", //商品列表
	productAdd: "product/add", //添加商品
	productDetails: "product/queryGoodsDetails", //商品详情
	productStatus: "product/updateTopOrDown", //商品发布
	productUpdate: "product/update", //修改商品

}

addApi(Api);